package com.fitso.model.dao.hibernate;

import javax.annotation.Resource;

import org.junit.runner.RunWith;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

import com.fitso.model.dao.FoodDao;
import com.fitso.model.dao.FoodDaoDB_IT;

/**
 * Hibernate implementation test of {@link FoodDao}
 * 
 * @author timothystorm
 */
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = { "classpath:fitso-model-context.xml" })
public class HibernateFoodDao_IT extends FoodDaoDB_IT {

	@Resource(name = "HibernateFoodDao")
	FoodDao _hibernateFoodDao;

	protected String[] getDataFileNames() {
		return new String[] { "src/test/resources/datasets/food_dataset.xml",
				"src/test/resources/datasets/food_serving_dataset.xml",
				"src/test/resources/datasets/food_description_dataset.xml",
				"src/test/resources/datasets/food_journal_dataset.xml" };
	}

	public FoodDao newFoodDao() {
		return _hibernateFoodDao;
	}
}